<template>
	<view>
		<view class="box">
			<view class="titleBox">
				<view class="titleReturn"><span><text class="iconfont icon-fanhui"></text></span></view>
				<view class="titleText">登录</view>
				<img src="https://youke1.picui.cn/s1/2025/11/03/69088724bbd62.png"/>
			</view>
			<view class="loginbox">
				<view class="loginway">
					<view class="logincode">
						验证码登录
					</view>
					<view class="loginpass">
						密码登录
					</view>
					<view class="inputBox">
						<view class="code">
							<input type="text" placeholder="请输入手机号" v-model="from.mobile"/>
						</view>
						<view class="pass">
							<input type="password" placeholder="请输入验证码" /><span @click="send">获取验证码</span>
						</view>
					</view>
				</view>
			</view>
			<button @click="$router.push('/pages/home/home')">登录</button>
			<span class="zhu" @click="$router.push('/pages/register/register')">没有账号,立即注册</span>
		</view>
	</view>
</template>

<script>
import {sendcode} from '@/apis/index.js'
	export default {
		data() {
			return {
				from:{}
			};
		},
		methods:{
			async send(){
				let red = await sendcode({mobile:this.from.mobile})
				console.log(red);
			}
		}
	}
</script>

<style lang="less">
	@import url(../../static/css/login.less);
	// @import url(../../iconfont/iconfont.css);
</style>
